<?php
namespace Home\Model;
use Think\Model;

class UserModel {
    //自动验证
    protected $_validate = array(
        array('username','require','账号必须！',1),
        array('username','','账号已经存在！',0,'unique',self::Model),
        array('username','administrator','用户名不能为administrator！'),
        array('pass','require','账号必须！',1),
        array('pass2','pass','两次密码不一致！',0,'confirm'),
        array('realname','require','真实姓名必须！'),
        array('email','require','邮箱必须！',1),

    );

}
